﻿using System;
using System.Collections.Generic;
using System.IO;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.Owin;
using Nancy;
using Nancy.Owin;
using Owin;

[assembly: OwinStartup(typeof(jczUserService.Startup))]

namespace jczUserService
{
    public class Startup
    {
        public void Configuration(IAppBuilder app)
        {
            // 有关如何配置应用程序的详细信息，请访问 https://go.microsoft.com/fwlink/?LinkID=316888
            app.UseCors(Microsoft.Owin.Cors.CorsOptions.AllowAll);
            app.UseNancy();
        }

        public class HomeModule : NancyModule
        {
            public HomeModule()
            {
                Get["/"] = x => {
                    return Response.AsRedirect("/index");
                };
               // Get["/login"] = x => { return "person name :" + Request.Query.name + " age : " + Request.Query.age; };
            }
        }
    }
}
